package com.clp.eduservice.controller;

import com.clp.utils.Result;
import org.springframework.web.bind.annotation.*;

/**
 * Create by chenlipeng on 2022/02/04 15:46
 */
@RestController
@RequestMapping("/eduService/user")
@CrossOrigin//解决跨域问题
public class EduLoginController {
    
    @PostMapping("/login")
    public Result login(){
        return Result.ok().data("token","admin");
    }
    
    @GetMapping("/info")
    public Result info(){
        return Result.ok().data("roles","[admin]").data("name","clp").data("avatar","https://wpimg.wallstcn.com/f778738c-e4f8-4870-b634-56703b4acafe.gif");
    }
}
